#ifndef __gm_framework_h__
#define __gm_framework_h__


#include "IGMApplication.h"
#include "GMWindows.h"
#include "../io/GMFileStream.h"


namespace app
{

class GMFramework : public app::IGMApplication
{	
	bool m_running;	
	app::GMWindows* meWindows;
	io::GMFileStream* meFilestream;	


public :
	GMFramework( HINSTANCE hInst, WNDPROC winproc = 0 );
	~GMFramework( void );
	
	static LRESULT CALLBACK default_winproc( HWND hWnd, unsigned int unMessage, WPARAM wParam, LPARAM lParam );

	bool running( void ) const { return m_running; }
	void running( bool val ) { m_running = val; }
	app::GMWindows* windows( void ) const { return meWindows; }


private :
	virtual bool initialize( void ) sealed override;
	virtual void destroy( void ) sealed override;
	
	bool load_app( void );
	void read_app_data( void );

};

};


#endif